Skip to content

feat: gitlab pipeline convert#2681

Closed
mappjzc wants to merge 1 commit into
apache:mainfrom
merico-ai:gitlab-ci
Closed

feat: gitlab pipeline convert#2681
mappjzc wants to merge 1 commit into
apache:mainfrom
merico-ai:gitlab-ci

Conversation

@mappjzc
Copy link
Copy Markdown
Contributor

@mappjzc mappjzc commented Aug 4, 2022

Summary

Add gitlab ConvertPipelines.

Does this close any open issues?

#2583

Screenshots

image
image

Other Information

Any other information that is important to this PR.

Add gitlab ConvertPipelines.

Nddtfjiang <zhicheng.jiang@merico.dev>
CommitSha: gitlabPipeline.Sha,
Branch: gitlabPipeline.Ref,
Repo: fmt.Sprintf("%d", gitlabPipeline.ProjectId),
Result: gitlabPipeline.Status,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

after pr #2683 get merged, please modify Result and Status, these two values should be enum

if gitlabPipeline.GitlabCreatedAt != nil {
createdAt = *gitlabPipeline.GitlabCreatedAt
}
finishedAt := time.Now()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if finishedAt should be nil?

Convert: func(inputRow interface{}) ([]interface{}, error) {
gitlabPipeline := inputRow.(*gitlabModels.GitlabPipeline)

createdAt := time.Now()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not use createdDate?

@mappjzc mappjzc mentioned this pull request Aug 5, 2022
@mappjzc mappjzc closed this in #2682 Aug 5, 2022
@mappjzc mappjzc deleted the gitlab-ci branch August 5, 2022 14:56
@mappjzc
Copy link
Copy Markdown
Contributor Author

mappjzc commented Aug 5, 2022

closed because it code move to #2682

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants